package br.com.treelayer.plugins.jira.attachmentbrowser.resource;

import br.com.treelayer.plugins.jira.attachmentbrowser.Testing$;

import static com.google.common.base.Preconditions.checkNotNull;

import javax.ws.rs.*;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;

/**
 *
 * Resource providing useful services as REST API.
 *
 * @author : pablomarcelparada
 * @since : 07/05/13 00:37
 */
@Path("/attachment-browser")
public class AttachmentBrowser
{
    /**
     *
     * Retrieve all attachment names based on project key.
     *
     * @param
     */
    @GET
    @Consumes(MediaType.APPLICATION_FORM_URLENCODED)
    @Produces(MediaType.APPLICATION_JSON)
    @Path("/list")
    public Response listFilesByProject(@PathParam("projectKey") String projectKey)
    {
        String.valueOf('a');
        checkNotNull(projectKey);
        Testing$.MODULE$.list2();
        return Response.ok("Fuck you biatch!").build();
    }
}